<template>
	<view>
		<view class="top">
<<<<<<< HEAD
			<view class="top_my">
				<view class="information_total">
					<view class="information_left" @click="tz_fn()">
						<img src="/static/images/avatar.png" class="image_left">
=======
			<view class="top_my">我的
				<view class="information_total">
					<view class="information_left" @click="tz_fn()">
						<img src="/static/avatar.png" class="image_left">
>>>>>>> f0751245c7fe0d7b25b59bf79787534b41c3a79c
					</view>
					<view class="information_center">
						<span @click="tz_fn()" class="information_center_one">{{yy.name}}</span></br>
						<span @click="tz_fn()" class="information_center_one">{{yy.phone}}</span></br>
						<span @click="tz_fn()" class="information_center_one">{{yy.shop_location}}</span>
					</view>
					<view class="information_center_flase" v-show="x1">
						您还没有登录，请登录！
					</view>
				</view>
				<view class="information_right" @click="quit_fn()">
					<view class="information_right_quit">
						退出登录
					</view>
				</view>
			</view>
		</view>
		<view class="items">
			<view class="item">
				<uni-icons type="info" size="30" class="my_icon"></uni-icons>
				帮助中心
				<uni-icons type="right" size="30" class="my_icon_right"></uni-icons>
			</view>
			<view class="item">
				<uni-icons type="person" size="30" class="my_icon"></uni-icons>
				关于我们
				<uni-icons type="right" size="30" class="my_icon_right"></uni-icons>
			</view>
			<view class="item">
				<uni-icons type="gear" size="30" class="my_icon"></uni-icons>
				设置
				<uni-icons type="right" size="30" class="my_icon_right_three"></uni-icons>
			</view>
		</view>

	</view>

</template>

<script>
	export default {

		data() {
			return {
				yy: '',
				x1: false,
			}
		},
		mounted: function(option) { //option为object类型，会序列化上个页面传递的参数
			// console.log(option); //打印出上个页面传递的参数。
			// var xx = option.id
			// console.log(xx)
			// var yy = JSON.parse(xx)
			// console.log(yy);

			// console.log("123123123")
			// console.log(localStorage.getItem("sx"));
		},
		onLoad() {
			uni.request({
				url:'http://localhost:3000/information',
				success: (res) => {
					console.log(res.data.data);
					this.yy=res.data.data[0];
					console.log(this.yy);
				}
			})
		},
		methods: {
			tz_fn() {
				uni.navigateTo({
<<<<<<< Updated upstream
<<<<<<< HEAD
					url: '../Personal_information/Personal_information',
=======
					url: '../my/Personal_information',
>>>>>>> f0751245c7fe0d7b25b59bf79787534b41c3a79c
					events: {
						sx: (xxx) => {
							console.log("sx 监听到数据了");
							console.log(xxx.xxx);

							this.yy = xxx.xxx
							console.log(this.yy);
						},
						someEvent: function(xxx) {
							console.log(xxx);
						},
						success: function(res) {
							console.log(res);
							res.eventChannel.emit('sx', {
								xxx: this.personal_information,
							})
						}

					}
=======
					url: '../my/Personal_information'
					
>>>>>>> Stashed changes
				})
			},
			quit_fn() {
				this.yy = '',
					this.x1 = true
			}
		}
	}
</script>

<style>
<<<<<<< HEAD
	.top {
		width: 100%;
		height: 200px;
		background-color: #fccc04;
	}

	.top_my {
		font-size: 25px;
		text-align: center;
		padding: 40px 0px 45px 0px;
		position: relative;
		/* display: flex; */
		/* flex-grow: 1; */
	}

	.information_total {
		width: 65%;
		/* position: absolute; */
	}

	a {
		text-decoration: none;
		margin-bottom: 5px;
	}

	.information_left {
		position: absolute;
		left: 15px;
		top: 100px;
	}

	.image_left {
		width: 50px;
		height: 50px;
	}

	.information_center {
		text-align: left;
		display: block;
		font-size: 18px;
		padding-left: 5px;
		position: absolute;
		left: 80px;
		top: 90px;
	}

	.information_center_one {
		font-style: oblique;
	}

	.information_right {
		position: relative;
		left: 290px;
		top: 50px;
		width: 100px;
		height: 30px;
		text-align: center;
		font-size: 16px;
		background-color: #655002;
		border-radius:13px;
	}

	.information_right_quit {
		text-align: center;
		position: relative;
		top: 4px;
		margin-left:-10px;
		color: white;
		
	}

	.items {
		margin-top: 25px;
		background-color: #fff;
		position: relative;
	}

	.item {
		font-size: 18px;
		padding: 15px 0px 15px 10px;
		border-bottom: 1px solid #bbb;
		/* position: absolute; */

	}

	.my_icon {
		position: relative;
		top: 5px;
		padding-right: 10px;
	}

	.my_icon_right {
		position: relative;
		top: 5px;
		right: -200px;
	}

	.my_icon_right_three {
		position: relative;
		top: 5px;
		right: -235px;
	}

	.information_center_flase {
		font-size: 18px;
		text-align: left;
		display: block;
		font-size: 18px;
		padding-left: 5px;
		position: absolute;
		left: 80px;
		top: 110px;
	}
=======
	@import './my.css'
>>>>>>> f0751245c7fe0d7b25b59bf79787534b41c3a79c
</style>
